<?php
class CheckMode_6
{

    public $acl;
    public $chkVal;
    public $systemcheck;

    public function CheckMode_6( $acl, $chkVal = 2 )
    {
        $conf = new Config();
        $this->systemcheck = $conf->Get( "systemcheck_6h" );
        $this->acl = $acl;
        $this->chkVal = $chkVal;
    }

    public function enableMode( )
    {
        global $g_init_mode_6h;
        if ( $g_init_mode_6h )
        {
            return false;
        }
        return true;
    }

    public function system6Check( )
    {
        if ( $this->acl == 255 )
        {
            return false;
        }
        if ( $this->systemcheck == 1 )
        {
            return true;
        }
        return false;
    }

    public function checkShow6Page( )
    {
        global $g_conf;
        $ui = new UI_3D( true );
        if ( $this->enableMode( ) )
        {
            //$ui->showErrorPage( "登入模式不含66，若有任何疑问，请洽管理者。" );
            //exit();
        }
        else
        {
            if ( $this->system6Check( ) )
            {
                $ui->showErrorPage( "系统维护中" );
                exit();
            }
        }
    }

}

?>